<section class='field'>
  {{auto-close-form autoCloseTime=category.auto_close_hours
                    autoCloseBasedOnLastPost=category.auto_close_based_on_last_post
                    autoCloseExamples=""
                    limited="true" }}
</section>

<section class='field'>
  <label>
    {{input type="checkbox" checked=category.allow_badges}}
    {{i18n 'category.allow_badges_label'}}
  </label>
</section>

<section class="field">
  <label>
    {{input type="checkbox" checked=category.suppress_from_homepage}}
    {{i18n "category.suppress_from_homepage"}}
  </label>
</section>

<section class="field">
  <label>
    {{input type="checkbox" checked=category.all_topics_wiki}}
    {{i18n "category.all_topics_wiki"}}
  </label>
</section>

{{#if siteSettings.topic_featured_link_enabled}}
  <section class='field'>
    <div class="allowed-topic-featured-link-category">
      <label class="checkbox-label">
        {{input type="checkbox" checked=category.topic_featured_link_allowed}}
        {{i18n 'category.topic_featured_link_allowed'}}
      </label>
    </div>
  </section>
{{/if}}

<section class="field">
  <label>
    {{i18n "category.sort_order"}}
    {{combo-box valueAttribute="value" content=availableSorts value=category.sort_order none="category.sort_options.default"}}
    {{#unless isDefaultSortOrder}}
      {{combo-box valueAttribute="value" content=sortAscendingOptions value=category.sort_ascending none="category.sort_options.default"}}
    {{/unless}}
  </label>
</section>

{{#if emailInEnabled}}
    <section class='field'>
      <label>
        {{input type="checkbox" checked=category.email_in_allow_strangers}}
        {{i18n 'category.email_in_allow_strangers'}}
      </label>
    </section>

    <section class='field'>
      <label>
        {{fa-icon "envelope-o"}}
        {{i18n 'category.email_in'}}
        {{text-field class="email-in" value=category.email_in}}
      </label>
    </section>

  {{plugin-outlet name="category-email-in" args=(hash category=category)}}
{{/if}}

{{#if showPositionInput}}
  <section class='field'>
    <label>
      {{i18n 'category.position'}}
      {{text-field value=category.position class="position-input"}}
    </label>
  </section>
{{/if}}

{{#unless emailInEnabled}}
  <section class='field'>
    {{i18n 'category.email_in_disabled'}}
    <a href="/admin/site_settings/category/email">{{i18n 'category.email_in_disabled_click'}}</a>
  </section>
{{/unless}}

{{#unless showPositionInput}}
  <section class='field'>
    {{i18n 'category.position_disabled'}}
    <a href="/admin/site_settings/category/basic">{{i18n 'category.position_disabled_click'}}</a>
  </section>
{{/unless}}

{{plugin-outlet name="category-custom-settings" args=(hash category=category)}}
